package com.example.redpocket.service.impl;

import com.example.redpocket.dao.RedPacketRecordRepository;
import com.example.redpocket.entity.RedPacketRecord;
import com.example.redpocket.entity.Result;
import com.example.redpocket.service.RedPacketRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class RedPacketRecordServiceImpl implements RedPacketRecordService {

    @Autowired
    RedPacketRecordRepository redPacketRecordRepository;

    @Override
    public Result saveRedPacketRecord(RedPacketRecord redPacketRecord) {

        redPacketRecordRepository.save(redPacketRecord);

        return Result.ok(redPacketRecord);
    }
}
